import request from '@/utils/request'

// 查询奶茶列表
export function listMilktea(query) {
    return request({
        url: '/repository/milktea/list',
        method: 'get',
        params: query
    })
}

// 查询奶茶详细
export function getMilktea(id) {
    return request({
        url: '/repository/milktea/' + id,
        method: 'get'
    })
}

// 新增奶茶
export function addMilktea(data) {
    return request({
        url: '/repository/milktea',
        method: 'post',
        data: data
    })
}

// 修改奶茶
export function updateMilktea(data) {
    return request({
        url: '/repository/milktea',
        method: 'put',
        data: data
    })
}

// 删除奶茶
export function delMilktea(id) {
    return request({
        url: '/repository/milktea/' + id,
        method: 'delete'
    })
}

// 导出奶茶
export function exportMilktea(query) {
    return request({
        url: '/repository/milktea/export',
        method: 'get',
        params: query
    })
}